package com.zhou.scaffolding.common;

public enum ErrorCode {
    SUCCESS("操作成功!",true,"200"),
    FAIL("操作失败",false,"400"),
    METHOD_NOT_SUPPORTED("Method Not Allowed",false,"405"),
    RUNTIME_ERROR("运行时异常,请联系管理员",false,"500"),
    ERROR("系统异常,请联系管理员",false,"-1");
    ;
    private String message;
    private boolean success;
    private String code;

    ErrorCode(String message, boolean success, String code) {
        this.message = message;
        this.success = success;
        this.code = code;
    }

    public String getMessage() {
        return message;
    }

    public boolean isSuccess() {
        return success;
    }

    public String getCode() {
        return code;
    }
}
